<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>@我的</title>
    <link rel="stylesheet" href="${base}/layui/css/layui.css">
    <link rel="stylesheet" href="${base}/awesome/css/font-awesome.min.css">
    <link rel="stylesheet" href="${base}/css/admin.css">
    <style>
    	.layui-bg-black{        width: 200px;height: 136px;margin-right: 30px;float: left;text-align: center;font-size: 33px;color: #000000!important;padding-top: 30px;}
    	.checkbox{display: inline-block;}
    	.layui-form-item{font-size: 18px;}
    </style>
</head>
<body  class="layui-layout-body" style="overflow:scroll;">
<#include "/common/left.flt">	
<div class="layui-main" style="position: absolute;left: 205px;top: 20px; width: calc(100% - 210px);" >
<fieldset class="layui-elem-field layui-field-title" style="margin-top: 10px;">
  <legend>操作提示</legend>
</fieldset>
<blockquote class="layui-elem-quote layui-quote-nm">
</blockquote> 
<div class="layui-form hide" id="discuss" style="padding-top:20px;padding-right:20px;">
  <div class="layui-form-item layui-form-text">
    <label class="layui-form-label">回复内容</label>
    <div class="layui-input-block">
      <input name="content" id="content" placeholder="请输入内容" class="layui-input" />
    </div>
  </div>
</div>
<table class="layui-table" >
	<thead>
        <tr>
             <tr>
                <th>编号</th>
                <th>登录名</th>
                <th>昵称</th>
                <th>性别</th>
                <th>@我的内容</th>
                <th>@我的时间</th>
                <th>会员到期</th>
                <th>操作</th>
            </tr>
         </tr>
     </thead>
     <tbody>
     <#list list as one>
     <tr>
     	<td>${one.id}</td>
     	<td>${one.user_mobile?default('')}</td>
     	<td><a href="${base}/users_list/detail?user_id=${one.user_id}" target="_blank">${one.nick_name?default('')}</a></td>
     	<td>${one.sex_name?default('')}</td>
     	<td>${one.content?default('')}</td>
     	<td>${one.create_time_string?default('')} </td>
     	<td>${one.vip_end_time_string?default('')} </td>
     	<td><a onclick="discuss(${one.id});" title="回复帖子评论"><span class="fa fa-comments-o"></span> 回复</a>
     	</td>
     </tr>
     </#list>
     </tbody>
</table>
<div id="pageDiv"></div>
</body>
<script src="${base}/js/jquery-2.1.4.min.js" type="text/javascript"></script>
<script src="${base}/layui/layui.all.js"></script>
<script type="text/javascript">
function discuss(id){
	layer.open({
	    type: 1 ,
	    title: '回复', 
	    area: ['600px', '400px'],   //宽高
	    shade: 0.4,   //遮罩透明度
	    content: $("#discuss"),
	    btn: ['确定'], //按钮组
	    scrollbar: false ,//屏蔽浏览器滚动条
	    yes: function(index){
	    	var content = $("#content").val();
	    	if (content){
	    		$.post("${base}/navy_user/answer",
				   		{"id":id,"content":content},function(data){ 
				   			layer.alert(data);
				   			$("#discuss").hide();
				   		}
				 );	
	    	}
	        layer.close(index);
	        
	        $("#discuss").hide();
	    },
		cancel: function(){
			$("#discuss").hide();        
	    }
	});
}
</script>
</html>